<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <title>消息发送记录</title>
    <?php require 'templates/common/head.html'; ?>
    <style type="text/css">
        .divleft{width: 10%; float: left; text-align:left; border-right: solid 1px #d5d5d5; margin-right: 2% }
        .divleft2{width: 18%; float: left; text-align:left; border-right: solid 1px #d5d5d5; margin-right: 2% }
        .divleft3{width: 7%; float: left; text-align:left; border-right: solid 1px #d5d5d5; margin-right: 2% }
        .divright{ width: 12%; float:right; text-align: right;}
    </style>
</head>
<body>


<div class="container-fluid">
    <?php require 'templates/common/nav.html'; ?>
    <div class="panel panel-primary">
        <div class="panel-heading text-center"><h3 class="panel-title">消息发送记录</h3></div>
        <div class="panel-body">
            <div class="panel-body">
                <div >
                    <form action="" method="get">
                        <input type="hidden" name="m" value="message_send_record"/>
                        <input type="text" name="messageId" placeholder="信息id" value="<?=$messageId?>">
                        <select name="send_status" style="height: 26px;">
                            <option value="">是否正常发送</option>
                            <option value="是" <?php if($sendStatus == '是') echo selected;  ?>>是</option>
                            <option value="否" <?php if($sendStatus == '否') echo selected;  ?>>否</option>
                        </select>
                        <input type="text" name="name" placeholder="请输入用户名" value="<?=$name?>">
                        <input type="submit" class="btn btn-success" value="搜索">
                    </form>
                </div>
            </div>
            <div class="panel-group"   id="accordion" role="tablist" aria-multiselectable="true">

                <div class="panel panel-default" >
                    <div class="panel-heading" style="background-color:#d5d5d5" >
                        <div class="row">
                            <div class="col-xs-4 text-justify" style="width:100%;">
                                <div class="divleft"><b  >接收消息用户名称</b></div>
                                <div class="divleft2"><b  >接收消息用户openID</b></div>
                                <div class="divleft3"><b  >消息类型</b></div>
                                <div class="divleft2"><b  >消息内容</b></div>
                                <div class="divleft3"><b  >是否正确发送</b></div>
                                <div class="divleft3"><b  >错误代码</b></div>
                                <div class="divleft3"><b  >信息id</b></div>
                                <div class="divright"><b  >发送日期</b></div>
<!--                                <div class="divright" > <b >操作</b></div>-->

                            </div>
                        </div>
                    </div>
                </div>
                <div class="panel panel-default">
                    <?php foreach($messageRecords as $key=>$value):?>
                        <div class="panel-heading"  style=" <?php if($key%2==0){echo "background-color:#DFF0D8;";}else{ echo "border-top: solid 2px #ffffff;";}?>">
                            <div class="row">
                                <div class="col-xs-4 text-justify" style="width:100%;">
                                    <div class="divleft"><span>&nbsp;<?= $value['name']?></span></div>
                                    <div class="divleft2"><span>&nbsp;<?=$value['接收消息用户openID']?></span></div>
                                    <div class="divleft3"><span>&nbsp;<?= $value['消息类型']?></span></div>
                                    <div class="divleft2"><span>&nbsp;<?=$value['消息内容']?></span></div>
                                    <div class="divleft3"><span>&nbsp;<?= $value['是否正确发送']?></span></div>
                                    <div class="divleft3"><span>&nbsp;<?= $value['错误代码']?></span></div>
                                    <div class="divleft3"><span>&nbsp;<?= $value['信息id']?></span></div>
                                    <div class="divright"><span><?= $value['发送时间']?></span></div>

                                </div>
                            </div>
                        </div>
                    <?php endforeach; ?>

                </div>
            </div>
        </div>
    <div><?= $page->showpage();?></div>
    </div>

</div>
<?php require 'templates/common/foot.html'; ?>
</body>
</html>